﻿// Decompiled with JetBrains decompiler
// Type: DnProcessSimulateCommands.SmartNotes.CApSmartNoteTypes
// Assembly: DnProcessSimulateCommands, Version=2402.0.0.890, Culture=neutral, PublicKeyToken=null
// MVID: A885D881-AEDF-447E-852A-6F13102E089C
// Assembly location: C:\Program Files\Tecnomatix_2402\eMPower\DotNetCommands\DnProcessSimulateCommands.dll

using DnProcessSimulateCommands.HeadUpWindow.SmartNoteHeadUpWindow;
using EngineeringInternalExtension;
using System.Collections.Generic;
using System.Linq;
using Tecnomatix.Engineering;


namespace DnProcessSimulateCommands.SmartNotes;

internal static class CApSmartNoteTypes
{
  private static string SmartNoteType_Collision = "Collision";
  private static string SmartNoteType_Warning = "Warning";
  private static string SmartNoteType_Checklist = "Checklist";
  private static string SmartNoteType_Ergonomics = "Ergonomics";
  private static string SmartNoteType_Info = "Info";
  private static string SmartNoteType_Safety = "Safety";
  private static Dictionary<string, string> s_NoteTypesLocalized = new Dictionary<string, string>()
  {
    {
      CApSmartNoteTypes.SmartNoteType_Collision,
      SmartNoteHUDWindowStringTable.NOTE_TYPE_COLLISION
    },
    {
      CApSmartNoteTypes.SmartNoteType_Warning,
      SmartNoteHUDWindowStringTable.NOTE_TYPE_GENERALWARNING
    },
    {
      CApSmartNoteTypes.SmartNoteType_Checklist,
      SmartNoteHUDWindowStringTable.NOTE_TYPE_TODO
    },
    {
      CApSmartNoteTypes.SmartNoteType_Ergonomics,
      SmartNoteHUDWindowStringTable.NOTE_TYPE_ERGONOMIC
    },
    {
      CApSmartNoteTypes.SmartNoteType_Info,
      SmartNoteHUDWindowStringTable.NOTE_TYPE_INFO
    },
    {
      CApSmartNoteTypes.SmartNoteType_Safety,
      SmartNoteHUDWindowStringTable.NOTE_TYPE_SAFETY
    }
  };

  internal static string TypeToLocalizedType(string type)
  {
    string str = "";
    return !CApSmartNoteTypes.s_NoteTypesLocalized.TryGetValue(type, out str) ? "" : str;
  }

  internal static string LocalizedType(this TxNote note)
  {
    return CApSmartNoteTypes.TypeToLocalizedType(TxGenericNoteEx.GetNoteProperty(note, "NoteType") as string);
  }

  internal static List<string> LocalizedList
  {
    get => CApSmartNoteTypes.s_NoteTypesLocalized.Values.ToList<string>();
  }

  internal static List<string> RawList
  {
    get => CApSmartNoteTypes.s_NoteTypesLocalized.Keys.ToList<string>();
  }
}
